﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.SessionState;
namespace WebUI.Services.UserDataVerity
{
    /// <summary>
    /// UVerity 的摘要说明
    /// </summary>
    public class UVerity : IHttpHandler, System.Web.SessionState.IRequiresSessionState
    {

        public void ProcessRequest(HttpContext context)
        {
            context.Response.ContentType = "text/plain";
            switch( context.Request["action"])
            {
                case "userlogined":
                    context.Response.Write( v_SessionMyAspxUser(context));
                    context.Response.End();
                    break;
            }
        }

        private string v_SessionMyAspxUser(HttpContext context)
        {
            if (context.Session["myaspxuser"] != null)
            {
                return "logined";
            }
            else
            {
                return "nologin";
            }
        }

        public bool IsReusable
        {
            get
            {
                return false;
            }
        }
    }
}